import request from "@/utils/request";
import {data} from "autoprefixer";




const  api_name = "/admin/product/brandCategory"

 export  const  getCategoryBrandPageList = (queryData)=>{
    return request({
        url:`${api_name}/${queryData.pageNum}/${queryData.pageSize}`,
        method:'get',
        params:queryData,
    })
 }

 export const addCategoryBrand= (categoryBrand)=>{
    return request({
        url:`${api_name}/addCategoryBrand`,
        method:'POST',
        data:categoryBrand
    })
 }

export const modifyCategoryBrand= (categoryBrand)=>{
    return request({
        url:`${api_name}/modifyCategoryBrand`,
        method:'PUT',
        data:categoryBrand
    })
}
// 根据分类的id获取品牌数据
export const FindBrandByCategoryId = categoryId => {
    return request({
        url: `${api_name}/findBrandByCategoryId/${categoryId}`,
        method: 'get',
    })
}


export const removeCateBrand= (categoryBrand)=>{
    return request({
        url:`${api_name}/removeCategoryBrand`,
        method:'delete',
        data:categoryBrand
    })
}